import Vue from 'vue'
import App from './App.vue'
import router from './router'
import './assets/fonts/iconfont.css'
import store from './store'
import './assets/css/reset.css'
import { Icon, Tabbar, TabbarItem, Swipe, SwipeItem, Grid, GridItem, List, PullRefresh, NavBar, GoodsAction, GoodsActionIcon, GoodsActionButton, Popup, Card, Stepper, Checkbox, SwipeCell, Button, SubmitBar, ContactCard, AddressList, AddressEdit, Form, Field, Search, Lazyload } from 'vant'
import loadingPlugin from '@/plugins/loading'
const img = require('./assets/img/loading.gif')
Vue.use(loadingPlugin)
/* import axios from 'axios'
Vue.prototype.$http = axios */
Vue.use(Icon)
  .use(Tabbar)
  .use(TabbarItem)
  .use(Swipe)
  .use(SwipeItem)
  .use(Grid)
  .use(GridItem)
  .use(List)
  .use(PullRefresh)
  .use(NavBar)
  .use(GoodsAction)
  .use(GoodsActionIcon)
  .use(GoodsActionButton)
  .use(Popup)
  .use(Card)
  .use(Stepper)
  .use(Checkbox)
  .use(SwipeCell)
  .use(Button)
  .use(SubmitBar)
  .use(ContactCard)
  .use(AddressList)
  .use(AddressEdit)
  .use(Form)
  .use(Field)
  .use(Search)
  .use(Lazyload)
Vue.config.productionTip = false
Vue.use(Lazyload, {
  preload: 1,
  loading: img
})
new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
